{% extends 'homepage.html' %}

{% block content %}

<!--{{ info.query }}-->


<h2> Further refine search </h2>

<form>
<input type="hidden" name="start" value="{{info.start}}"/>
<table border="0">

<tr>
<td align=left> {{ KNOWL('ec.q.conductor', title='Conductor') }} <input type='text' name='conductor' size=10 value={{info.conductor}}></td>
<td align=left>{{ KNOWL('ec.q.rank', title='Rank') }}<input type='text' name='rank'size=1 value={{info.rank}}></td>
<td align=left>{{ KNOWL('ec.q.torsion_order', title='Torsion order') }} <input type='text' name='torsion' size=1 value={{info.torsion}}> </td>
<td align=left>{{ KNOWL('ec.q.torsion_subgroup', title='Torsion structure') }} <input type='text' name='torsion_structure' size=1 value={{info.torsion_structure}}> </td>
<td align=left>{{ KNOWL('ec.q.analytic_sha_order', title='Analytic order of &#1064;\(_{an} \)') }} <input type='text' name='sha_an' size=1 value={{info.sha_an}}> </td>
<td align=left>
<td align=left>{{ KNOWL('ec.q.optimal', title='Optimal only') }}
<select name='optimal'>
{% if info.optimal=='on' %}
  <option value="">No</option>
  <option selected="yes" value="on">Yes</option>
{% else %}
  <option value="">No</option>
  <option value="on">Yes</option>
{% endif %}
</select>
</td>
</tr>
<tr>
<td align=left colspan=4>Maximum number of curves to display <input type='text' name='count' value={{info.count}} size=10>
</td>
</tr>

<tr> <td>
<button type='submit' value='refine'>Search again</button>
</td> </tr>
</table>
</form>

<style type="text/css">
table td.center {
  text-align: center;
}
table td.params {
  text-align: left;
  font-family: monospace;
}

</style>

<h2> Results ({{info.report}})</h2>
<table>
<tr>
  <th class="center">{{ KNOWL('ec.isogeny_class', title='Isogeny class') }}</th>
  <th class="center">{{ KNOWL('ec.q.lmfdb_label', title='LMFDB label')}}</th>
  <th class="center">{{ KNOWL('ec.q.cremona_label', title='Cremona label')}}</th>
  <th align="left">[a<sub>1</sub>,  a<sub>2</sub>, a<sub>3</sub>, a<sub>4</sub>, a<sub>6</sub>]</th>
  <th class="center">{{ KNOWL('ec.q.rank', title='Rank') }}</th>
  <th class="center">{{ KNOWL('ec.q.torsion_order', title='Torsion order') }}</th>
</tr>
{% for curve in info.curves: %}
<tr>
<td class="center"><a href="/EllipticCurve/Q/{{curve.lmfdb_iso}}">{{curve.lmfdb_iso}}</a></td>
<td class="center"><a href="/EllipticCurve/Q/{{curve.lmfdb_label}}">{{curve.lmfdb_label}}</a></td>
<td class="center">{{curve.label}}</td>
<td class="params">{{info.format_ainvs(curve.ainvs)}}</td>
<td class="center"><a href="/EllipticCurve/Q?conductor={{info.conductor}}&rank={{curve.rank}}&torsion={{info.torsion}}&torsion_structure={{info.torsion_structure}}&sha_an={{info.sha_an}}">{{curve.rank}}</a></td>
<td class="center"><a href="/EllipticCurve/Q?conductor={{info.conductor}}&rank={{info.rank}}&torsion={{curve.torsion}}&torsion_structure={{info.torsion_structure}}&sha_an={{info.sha_an}}">{{curve.torsion}}</a></td>
</tr>
{% endfor %}
</table>

<hr>
<a href="#" class="navlink" onclick="decrease_start_by_count_and_submit_form();return false">Previous</A>
<a href="#" class="navlink" onclick="increase_start_by_count_and_submit_form();return false">Next</A></td>

{#
Query was: {{info.query}}
#}

{% endblock %}
